"""
    面向对象：封装，私有方法和私有变量
    私有的处理方式：在变量前面加上 "__"
"""

class Person:
    __home = "海南省海口市"
    def __init__(self, name, age):
        self.__name = name
        self.age = age

    def __eat(self):
        print("eating......")

    def eat_1(self):
        print("eating......")
        print(self.__home)
        print(self.__name)
        self.__eat()

# print(Person._Person__home)

person = Person("张三", 30)

# 不可以访问，只能在内部访问
# print(person.__home)

person.eat_1()
# person.__eat()

# 底层处理
print("底层处理方式================")
person._Person__eat()



